package com.hejielife.singlethreadedexecution1;

/**
 * 2019年8月2日 上午10:15:57
 * 
 * @author hejielife
 * @despribe 通过这扇门的只有一个人。<br>
 * 共享资源：门
 * 
 */
public class Main {
	public static void main(String[] args) {
		System.out.println("Testing Gate, hit CTRL+C to exit.");
		Gate gate = new Gate();
		new UserThread(gate, "Alice", "Alaska").start();
		new UserThread(gate, "Bobby", "Brazil").start();
		new UserThread(gate, "Chris", "Canada").start();
	}
}
